home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Belgian Amiga Club - ADF Collection
/
BS1 part 05.zip
/
BS1 part 5
/
ANC_UTULITYS_16.adf
/
3util.arc
/
utiltex
< prev
next >
Wrap
Text File
|
1988-09-21
|
3KB
|
52 lines
---------------------------------------
3]BATCHER - UNLOCK DIRECTORY - WORD COUNT
3]Three Tiny But Helpful Utilities
3]By WESLEY HOWE
---------------------------------------
With an eye toward economy of bytes, I've written three small utilities
you may be able to use. All three are only executable from the CLI.
3]BATCHER
Batcher is a 216-byte Assembly program that allows batch files to be
executed from the CLI without explicitly using the execute command. It
operates by looking for the name by which it was executed, appending the
suffix ".bat" to this name. It attempts to execute it, using the AmigaDOS
execute function, passing any remaining parameters on the command-line tail
to the batch file. The program "RUN" needs to be in the C directory for this
to work.
To use it, rename the assembled program from "Batcher" to the name of
the DOS batch file you want to execute, and rename the batch file to the
same name with ".bat" on the end. For example, to execute a 'C' compilation
and link, make a batch file to do this named "cc.bat". Copy Batcher to cc.
Then you can execute the compilation by typing "cc <program name>" from the
CLI.
3]UD -- UNLOCK DIRECTORY
UD is a 108-byte Assembly-language program to unlock the current
Directory and set it to the root of the filing system (the boot disk). UD
was written to overcome the problem where the CD command attaches to a disk,
rather than a device.
It is most useful on single-drive systems, where swapping disks can
become a problem. For example, if you use CD on a single drive system even
once, you must use it each time you change the disk in DF0: or the system
will keep asking for the old disk by name.
On two-drive systems, it is often more convenient to move the bootdisk
to DF1: and change disks in DF0:. If you use CD to inspect a directory, then
use CD DF0: to get out, you will need to use CD DF0: each time you want to
change the disk in DF0:. I find that cumbersome and inconvenient.
Enter UD. After using the CD command, UD will set the current directory
to the disk drive DF0:, not the volume in DF0:. This is the way the system
defines the current directory after a reboot prior to ever using the CD
command.
WC -- WORD COUNT
WC is a 864-byte assembly-language utility to count the characters,
lines and words in a text file. To use it, simply type WC followed by a
filename from the CLI.
WC defines a "word" as a sequence of characters bounded by either
spaces, tab or newlines (linefeeds). It considers lines to be sequences of
characters terminated with newlines.
4]END OF TEXT